package com.sinoair.util;

/**
 * layuiDemo
 * HTML 工具类
 * <pre>
 *  Version         Date            Author          Description
 * ---------------------------------------------------------------------------------------
 *  1.0.0           2017/09/10     senlin        -
 * </pre>
 *
 * @author senlin
 * @version 1.0.0 2017/9/10 0010 9:38
 * @date 2017/9/10 0010 9:38
 * @since 1.0.0
 */
public class HTMLUtil {

    public static String htmlspecialchars(String str) {
        str = str.replaceAll("&", "&amp;");
        str = str.replaceAll("<", "&lt;");
        str = str.replaceAll(">", "&gt;");
        str = str.replaceAll("\"", "&quot;");
        return str;
    }
}
